import com.guigu.lqxm.jy.service.JyService;
import com.guigu.lqxm.jy.service.impl.JyServiceImpl;
import com.guigu.lqxm.lq.service.TestService;
import org.junit.Test;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import java.util.List;

public class T1 {
    @Test
    public void t1(){
      ApplicationContext app = new ClassPathXmlApplicationContext("SpringApplicationConfing.xml");
        TestService bean = app.getBean(TestService.class);
        List<com.guigu.lqxm.pojo.Test> tests = bean.selectAll();
        System.out.println(tests);

    }

    @Test
    public void t2(){
        ApplicationContext app = new ClassPathXmlApplicationContext("SpringApplicationConfing.xml");
        JyService bean = app.getBean(JyServiceImpl.class);
        int del = bean.del2(4);
        System.out.println(del);
    }
}
